扫一扫
分享文章到微信
扫一扫
关注官方公众号
至顶头条
作者:builder.com.cn 2007年4月6日
关键字: SQL Server
在本页阅读全文(共8页)
ServerA:
CREATE VIEW dpv_SalesHistory
AS
SELECT
SaleID, Product, Region, SaleDate, SalePrice
FROM SalesDB.dbo.SalesHistory
UNION ALL
SELECT
SaleID, Product, Region, SaleDate, SalePrice
FROM ServerB.SalesDB.dbo.SalesHistory
ServerB:
CREATE VIEW dpv_SalesHistory
AS
SELECT
SaleID, Product, Region, SaleDate, SalePrice
FROM SalesDB.dbo.SalesHistory
UNION ALL
SELECT
SaleID, Product, Region, SaleDate, SalePrice
FROM ServerA.SalesDB.dbo.SalesHistory
濡傛灉鎮ㄩ潪甯歌揩鍒囩殑鎯充簡瑙T棰嗗煙鏈€鏂颁骇鍝佷笌鎶€鏈俊鎭紝閭d箞璁㈤槄鑷抽《缃戞妧鏈偖浠跺皢鏄偍鐨勬渶浣抽€斿緞涔嬩竴銆�